package com.hoshiicloud.common.constant.refund;

/**

 * @author: qry
 * @descripton: 退款单状态枚举
 * @date: 14:02 2019/8/22
 */
public enum RefundOrderStatusEnum {

    WAIT_SELLER_HANDLE(1,"等待商家处理"),
    WAIT_BUYER_DELIVERY(2,"等待买家发货"),
    WAIT_SELLER_RECEIVE(3,"等待商家收货"),
    WAIT_SELLER_PAY(4,"等待商家打款"),
    REFUND_SUCCESS(5,"退款成功"),
    SELLER_REFUSE_REFUND(6,"商家拒绝退款"),
    REFUND_CANCEL(7,"退款已取消"),
    BANK_PROCESSING(8,"银行处理中"),
    SYS_RECORD(20,"系统提示记录")


    ;
    private int code;

    private String name;

    RefundOrderStatusEnum(int code, String name) {
        this.code = code;
        this.name = name;
    }

    public int getCode() {
        return this.code;
    }

    public String getName() {
        return this.name;
    }


    public static String getStatusCn(int code){
        for (RefundOrderStatusEnum aparameterStatus : values()) {
            if (aparameterStatus.getCode() == code) {
                return aparameterStatus.getName();
            }
        }
        return "未匹配到";
    }
}
